import React from "react";
import { Outlet, useNavigate } from "react-router-dom";
import { Tabbar } from "react-vant";
import { housrouters } from "../../router";
function Index() {
  let nav = useNavigate();
  return (
    
    <div>
      <Outlet></Outlet>
      <Tabbar onChange={(key)=>nav(key)}>
        {
            housrouters.map((item,index)=>(
            <Tabbar.Item key={index} icon={item.icon} name={item.path}>{item.title}</Tabbar.Item>
            ))
        }
        
        
      </Tabbar>
    </div>
  );
}

export default Index;
